kfraser@localhost.localdomain [Wed, 1 Nov 2006 11:18:29 +0000 (11:18 +0000)]
[XEN] Extend dom0_mem syntax to support min/max clamps.
dom0_mem=[min:<min_amt>,][max:<max_amt>,][<amt>]
<min_amt>: The minimum amount of memory which should be allocated for dom0.
<max_amt>: The maximum amount of memory which should be allocated for dom0.
<amt>: The precise amount of memory to allocate for dom0.
Notes:
1. <amt> is clamped from below by <min_amt> and from above by available
memory and <max_amt>
2. <min_amt> is clamped from above by available memory and <max_amt>
3. <min_amt> is ignored if it is greater than <max_amt>
4. If <amt> is not specified, it is calculated as follows:
"All of memory is allocated to domain 0, minus 1/16th which is reserved
for uses such as DMA buffers (the reservation is clamped to 128MB)."
Each value can be specified as positive or negative:
If +ve: The specified amount is an absolute value.
If -ve: The specified amount is subtracted from total available memory.
Signed-off-by: Keir Fraser <keir@xensource.com>
Ewan Mellor [Wed, 1 Nov 2006 10:41:44 +0000 (10:41 +0000)]
Merge.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
Ewan Mellor [Wed, 1 Nov 2006 10:40:46 +0000 (10:40 +0000)]
Merge xen-api.hg changeset 142:
d75413e65ba319d577c764be6c13efa5eae6da1c.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
Tim Deegan [Wed, 1 Nov 2006 10:31:11 +0000 (10:31 +0000)]
[XEN] Prefetch multiple shadow entries per pagefault
Also, clean up the shadow *_propagate/fault routines.
This allows us to quickly dispatch some guest-not-present faults
and most MMIO accesses without taking the shadow lock.
Signed-off-by: Tim Deegan <Tim.Deegan@xensource.com>
kfraser@localhost.localdomain [Wed, 1 Nov 2006 10:02:00 +0000 (10:02 +0000)]
[XEN] Fix building on OpenBSD.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Wed, 1 Nov 2006 09:55:43 +0000 (09:55 +0000)]
[XEN] Fix deadlock in printk().
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 18:24:57 +0000 (18:24 +0000)]
Stop enforcing -g for some of the tools.
Signed-off-by: John Levon <john.levon@sun.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 18:24:44 +0000 (18:24 +0000)]
[XEND] Improve error message for unparsed disk modes.
Signed-off-by: John Levon <john.levon@sun.com>
Tim Deegan [Tue, 31 Oct 2006 16:42:46 +0000 (16:42 +0000)]
[HVM] Use correct types for guest physical addresses
Guest physical addresses are not guaranteed to fit in either a pointer
or an unsigned long int; use paddr_t for them.
Signed-off-by: Tim Deegan <Tim.Deegan@xensource.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 16:22:39 +0000 (16:22 +0000)]
[HVM] Add support for 'add r8,m8' instruction to memory-mapped I/O.
Signed-off-by: Kevin Tronkowski <ktronkowski@virtualiron.com>
Signed-off-by: Ben Thomas <bthomas@virtualiron.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 16:18:07 +0000 (16:18 +0000)]
[NET] front: Clean up error handling. This eliminates earlier
workaround patch for an observed crash.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 15:54:03 +0000 (15:54 +0000)]
Clean up recent changes to reboot code. This fixes PV save/restore.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 15:04:05 +0000 (15:04 +0000)]
Update .hgignore
kfraser@localhost.localdomain [Tue, 31 Oct 2006 14:39:50 +0000 (14:39 +0000)]
[HVM] vlapic: Synchronously determine PPR register value whenevr it is needed.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 13:26:49 +0000 (13:26 +0000)]
[VMX] Replace vmx_load_cr2() with direct write to %cr2.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Tue, 31 Oct 2006 12:42:50 +0000 (12:42 +0000)]
[HVM] ACPI: Clean up table definitions, move under hvmloader/
directory pending tighter integration of table generation
into hvmloader. This patch also includes the TPM TIS SSDT
generator from Stefan Berger at IBM.
Signed-off-by: Keir Fraser <keir@xensource.com>
Steven Smith [Tue, 31 Oct 2006 11:44:47 +0000 (11:44 +0000)]
Merge.
Steven Smith [Tue, 31 Oct 2006 11:44:28 +0000 (11:44 +0000)]
[XEN] Add a warning to the i8259 if we generate spurious IRQs. Tidy up
a little while I'm here.
Signed-off-by: Steven Smith <sos22@cam.ac.uk>
Steven Smith [Tue, 31 Oct 2006 11:38:55 +0000 (11:38 +0000)]
[PV-ON-HVM] Don't generate lots of spurious interrupts when using event
channel upcalls.
The issue here was that the Xen platform PCI interrupt is only updated
when you return from the hypervisor into guest context, and so remained
asserted for a short interval after the interrupt handler ran. If
it happened that the first subsequent trap to the hypervisor was
for unmasking the 8259 interrupt again, the unmasking caused the interrupt
to be reinjected. This caused an edge on the chaining interrupt from
the slave PIC to the master. The platform interrupt on the slave
would then be cleared as we returned to the guest, and so you
eventually end up injecting an interrupt on the master chained
interrupt with nothing pending on the slave, which shows up as
a spurious interrupt in the guest.
Signed-off-by: Steven Smith <sos22@cam.ac.uk>
Steven Smith [Tue, 31 Oct 2006 11:31:34 +0000 (11:31 +0000)]
[NETFRONT] Make sure we don't crash if the backend goes to state
Closing before we have a chance to connect. This can happen if
there's an error while connecting.
Signed-off-by: Steven Smith <sos22@cam.ac.uk>
Steven Smith [Tue, 31 Oct 2006 10:12:35 +0000 (10:12 +0000)]
Merge.
Steven Smith [Tue, 31 Oct 2006 10:11:53 +0000 (10:11 +0000)]
[HVM][LINUX][TOOLS] Split control/reboot_module into control/feature-reboot
and control/feature-sysrq. This is more consistent with the other
PV device protocols.
Signed-off-by: Steven Smith <sos22@cam.ac.uk>
Emmanuel Ackaouy [Tue, 31 Oct 2006 10:10:17 +0000 (10:10 +0000)]
[XEN] Cleanup and optimize layout of credit scheduler stats.
Also carve out per VCPU stats for clarity and add per-VCPU
migration counter.
Signed-off-by: Emmanuel Ackaouy <ack@xensource.com>
Steven Smith [Tue, 31 Oct 2006 09:54:49 +0000 (09:54 +0000)]
[HVM][LINUX][TOOLS] Make xm {shutdown|reboot} do something sensible for HVM
domains with PV drivers loaded. This patch creates a new PV-on-HVM
module, reboot.ko, which, when loaded, creates control/reboot_module
in the store. The tools notice this, and disable the watch which would
normally destroy HVM domains which are the target of an xm shutdown
command, allowing the reboot module to shut the domain down cleanly.
Signed-off-by: Tetsu Yamamoto <yamamoto.tetsu@jp.fujitsu.com>
(Checkin comments by Steven Smith <sos22@cam.ac.uk>)
kfraser@localhost.localdomain [Tue, 31 Oct 2006 09:49:31 +0000 (09:49 +0000)]
[NET] back: Remove warning about non-zero tx queue length.
Signed-off-by: Keir Fraser <keir@xensource.com>
Emmanuel Ackaouy [Mon, 30 Oct 2006 17:35:11 +0000 (17:35 +0000)]
[XEN] Cleanup and improve accuracy of credit scheduler accounting code
Signed-off-by: Emmanuel Ackaouy <ack@xensource.com>
kfraser@localhost.localdomain [Mon, 30 Oct 2006 14:28:29 +0000 (14:28 +0000)]
[LINUX] Fix build breakage from previous patch.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Mon, 30 Oct 2006 14:14:46 +0000 (14:14 +0000)]
[LINUX] Use CONFIG_XEN_COMPAT_030002 where possible.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
kfraser@localhost.localdomain [Mon, 30 Oct 2006 14:09:13 +0000 (14:09 +0000)]
[LINUX] Declare structs as 'static __initdata' where possible.
Probably still not catching all possible cases, but using static
(where not already the case) makes the code size smaller, and using __initdata
has the usual advantages.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
kfraser@localhost.localdomain [Mon, 30 Oct 2006 14:04:44 +0000 (14:04 +0000)]
[LINUX] privcmd: Range-check hypercall index.
Otherwise, bugs in e.g. libxc may bring the kernel down.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
kfraser@localhost.localdomain [Mon, 30 Oct 2006 13:53:09 +0000 (13:53 +0000)]
[XEN] HVM: Clean up and simplify vlapic device-model code.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Mon, 30 Oct 2006 10:42:27 +0000 (10:42 +0000)]
[HVM][VMX] Enable VMX TPR shadow feature.
x64 Windows uses CR8 to access TPR very frequently. This patch enables
TPR shadow and allows mov-from/to-CR8 to access it directly; tests
indicates it can boost greatly the performance of x64 Windows 2003.
Signed-off-by: Eddie Dong <eddie.dong@intel.com>
Signed-off-by: Yunhong Jiang <yunhong.jiang@intel.com>
Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
kfraser@localhost.localdomain [Mon, 30 Oct 2006 09:45:17 +0000 (09:45 +0000)]
[HVM] Fix Qemu-dm serial issues:
1. Retry transmit via a polling timer if a byte cannot be written
immediately to its destination.
2. Turn off output processing of raw serial lines.
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
Signed-off-by: Yunhong Jiang <yunhong.jiang@intel.com>
Signed-off-by: Keir Fraser <keir@xensource.com>
Ewan Mellor [Sun, 29 Oct 2006 19:28:26 +0000 (19:28 +0000)]
Fix handling of SXP for devices through device_add -- this solves the
Invalid device (uname) problem that breaks just about everything once you've
done xm block-attach.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
kaf24@firebug.cl.cam.ac.uk [Sat, 28 Oct 2006 11:30:38 +0000 (12:30 +0100)]
[XEN] Add implicit "\n" back into MEM_LOG(). Removed by mistake.
Signed-off-by: Keir Fraser <keir@xensource.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 22:47:30 +0000 (23:47 +0100)]
[XEN] Some cleanups to the log-level stuff. Largely this
is a rename and slight interface change to DPRINTK (now
replaced by dprintk() and gdprintk()). Also shuffle some
log-level definitions around and tweak the semantics of
the upper threshold.
Signed-off-by: Keir Fraser <keir@xensource.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 18:15:48 +0000 (19:15 +0100)]
[QEMU] Add a TIS device model compliant to the 1.2 TPM specification.
It implements all registers necessary to make the Linux TIS driver
work (tpm_tis.c). All of the basic registers supported by this type of
device are implemented. Also the locality selection has been
implemented, but has not been tested. The legacy registers as
described in the specification are not supported.
Current caveat: The device has so far not yet been integrated with the
virtual TPM available in the repository. It will require changes to
the virtual TPM spawned by the vTPM manager to offer an additional message
interface. The TIS interface itself then needs to have an additional
transport implemented. (see vTPMTransmit array).
The relevant specification for the device model can be found here:
https://www.trustedcomputinggroup.org/groups/pc_client/TCG_PCClientTPMSpecification_1-20_1-00_FINAL.pdf
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 18:13:51 +0000 (19:13 +0100)]
[QEMU] Helper functions to interface with the xenstore and read device information from it.
- detect what types of devices a domain has or whether a domain has a
device of a certain type
- read the content of a variable related to a device, i.e.,
hotplug-status
- subscribe to changes of the hotplug status of a device for not
having to poll the status
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:57:02 +0000 (18:57 +0100)]
[XEN] Logging parameters for ia64 code.
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:56:44 +0000 (18:56 +0100)]
[XEN] Logging parameters for powerpc code.
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:56:24 +0000 (18:56 +0100)]
[XEN] Logging parameters for x86 code.
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:55:16 +0000 (18:55 +0100)]
[XEN] Logging parameters for common code.
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:52:55 +0000 (18:52 +0100)]
[XEN] Implement log levels. It adds the thresholds and code to printk
to implement the thresholds.
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:46:20 +0000 (18:46 +0100)]
[XEN] Implement rate-limited logging.
Taken from Andi Kleen's rate limit in the Linux kernel.
This keeps large amounts of prints in the HV down.
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:15:14 +0000 (18:15 +0100)]
[XEND] Do not delete VNC password from configuration.
Fixes reboot of HVM guest when VNC authentication is in use.
Signed-off-by: Keir Fraser <keir@xensource.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:15:14 +0000 (18:15 +0100)]
[XEND] Do not delete VNC password from configuration.
Fixes reboot of HVM guest when VNC authentication is in use.
Signed-off-by: Keir Fraser <keir@xensource.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:10:37 +0000 (18:10 +0100)]
[XEN] perf counters: Fix NULL-pointer check. Should happen later.
Signed-of-by: Kouya Shimura <kouya@jp.fujitsu.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:02:40 +0000 (18:02 +0100)]
[HVM] Ensure that, if AP is blocked, it is woken by interrupt delivered by IOAPIC.
This fixes 64-bit SMP Windows 2k3 boot.
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
Signed-off-by: Xin Li <xin.b.li@intel.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 17:00:03 +0000 (18:00 +0100)]
[HVM] Fix SMP timer issues:
* Sync AP TSCs with BP at startup
* Only halt BP TSC when descheduled
* Correctly handle IPIs on timer vector
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
kaf24@localhost.localdomain [Fri, 27 Oct 2006 16:50:40 +0000 (17:50 +0100)]
[QEMU] ne2000: Stop memory access beyond buffer
As a program that runs in dom0 which serves users from guests,
the qemu drivers need to be vigilant to the input that comes
from the guests since they may be malicious.
As it is there are multiple ways to get ne2000 to read/write
memory beyond the 48K buffer that it has allocated for each
adapter.
This patch checks the addresses and prevents this from occuring.
The boundary is checked each time since it's changed for every
packet received while the other parameters are only changed
(by the guest) during setup.
Signed-off: Herbert Xu <herbert@gondor.apana.org.au>
Emmanuel Ackaouy [Fri, 27 Oct 2006 14:44:27 +0000 (15:44 +0100)]
Improve I/O performance when competing with CPU intensive workloads.
Allow non CPU consuming wake-to-run latency sensitive VCPUs to
preempt CPU consuming ones.
Signed-off-by: Emmanuel Ackaouy <ack@xensource.com>
Ian Campbell [Thu, 26 Oct 2006 15:56:16 +0000 (16:56 +0100)]
[TOOLS] Uncompress and allocate memory for gzipped kernel and initrd images on
the fly. We cannot rely on the length contained in the gzip trailer to determine
the length of the decompressed data because images have been observed which have
trailing junk.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Tim Deegan [Thu, 26 Oct 2006 14:08:20 +0000 (15:08 +0100)]
[HVM] Fix qemu's test for whether physcal addresses are RAM.
HVM guests have a memory hole below 4GB, so can't just check whether
addresses are < the amount of RAM allocated.
Signed-off-by: Tim Deegan <Tim.Deegan@xensource.com>
kfraser@localhost.localdomain [Thu, 26 Oct 2006 10:50:17 +0000 (11:50 +0100)]
[NET] back: Advertise that we do not support rx-flip path any more.
This will now be used only by older guests who do not understand
the feature-rx-{copy,flip} feature flags.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Thu, 26 Oct 2006 10:26:05 +0000 (11:26 +0100)]
Merge with xen-isa64-unstable.hg
Ewan Mellor [Thu, 26 Oct 2006 09:20:22 +0000 (10:20 +0100)]
Fix ramdisk Makefile so that downloading from xm-test.xensource.com actually
works.
Signed-off-by: Tony Breeds <tony@bakeyournoodle.com>
awilliam@xenbuild.aw [Wed, 25 Oct 2006 21:29:00 +0000 (15:29 -0600)]
[LIBXC][IA64] fix build warning
With warnings becoming errors, this fixes the libxc build on ia64
Signed-off-by: Alex Williamson <alex.williamson@hp.com>
awilliam@xenbuild.aw [Wed, 25 Oct 2006 20:48:55 +0000 (14:48 -0600)]
[IA64] NUMA support
Based on patch from Tristan Gingold
Signed-off-by: Alex Williamson <alex.williamson@hp.com>
awilliam@xenbuild.aw [Wed, 25 Oct 2006 18:12:01 +0000 (12:12 -0600)]
merge with xen-unstable.hg
kfraser@localhost.localdomain [Wed, 25 Oct 2006 14:29:36 +0000 (15:29 +0100)]
[IA64][HVM][QEMU] Add buffer IO mechanism for IA64/VTi domain.
Signed-off-by:Zhang xiantao <xiantao.zhang@intel.com>
Ewan Mellor [Wed, 25 Oct 2006 14:29:08 +0000 (15:29 +0100)]
Import Xend part of xen-unstable changeset
11922:
1e6b0a8a0822a22d313d9058fa0dc10c7a319821.
[IA64][HVM] Add buffer IO mechanism for Xen/VTi domain. Current
implementation can accelerate Windows guest's dense IO operations
at boot time.
Signed-off-by: Zhang xiantao <xiantao.zhang@intel.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 14:29:08 +0000 (15:29 +0100)]
[IA64][HVM] Add buffer IO mechanism for Xen/VTi domain. Current
implementation can accelerate Windows guest's dense IO operations
at boot time.
Signed-off-by: Zhang xiantao <xiantao.zhang@intel.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 14:25:13 +0000 (15:25 +0100)]
[LIBXC] Add -Wmissing-prototypes to CFLAGS, fix warnings resulting from that.
Signed-off-by: Gerd Hoffmann <kraxel@suse.de>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 14:17:40 +0000 (15:17 +0100)]
[XEN] Clean up NUMA stuff and disable by default ('numa=on' enables it).
Signed-off-by: Keir Fraser <keir@xensource.com>
Ewan Mellor [Wed, 25 Oct 2006 14:01:51 +0000 (15:01 +0100)]
Print the time to xend-debug.log, when starting or restarting Xend.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
Ewan Mellor [Wed, 25 Oct 2006 14:01:51 +0000 (15:01 +0100)]
Print the time to xend-debug.log, when starting or restarting Xend.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-to-HVM: Add a compatibility define for the end_that_request_last
which changed prototype in 2.6.16.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Include compatibility kzalloc implementation for kernels
before 2.6.14.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-to-HVM: Impletement compatibility version of
schedule_timeout_interruptible for kernels before 2.6.14
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Implement and export a compatibility version of do_exit().
Kernels prior to 2.6.12 did not export do_exit().
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Implement compatibilty version of wait_for_completion_timeout
for kernels before 2.6.11
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Include compatability vmalloc_to_pfn for kernels before 2.6.10
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Kernels prior to 2.6.8 did not export strcspn to modules
therefore implement our own and export it.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Define system_state as 1 (SYSTEM_RUNNING) on kernels prior
to 2.6.7. These kernels did not export the system_state variable to
modules.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-to-HVM: Implement compatibility nonseekable_open as a nop on
kernels before 2.6.9
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-to-HVM: Add compatibility definitions of various #defines when they
are not present in the kernel we are building against.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Include compatability headers for asm/pgtable-no{pmd,pud}.h
for kernels before 2.6.11.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Add a compatibility linux/mutex.h for kernels before
2.6.16. This implements the new mutex type in terms of the old
semaphore type.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Add a compatibility linux/io.h for kernels before 2.6.16
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Add infrastructure for a compatibility shim in order to
support PV-on-HVM drivers for older kernel releases.
The compatability code is included in the xen-platform-pci module
since this module underpins all the others.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] PV-on-HVM: The elevator_init prototype changed in 2.6.10
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] PV-on-HVM: Implement HDIO_GETGEO ioctl on kernels before
2.6.16.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] PV-on-HVM: The probe, remove and shutdown methods were added
to struct bus_type in 2.6.16. For older kernels use the methods on the
struct device_driver.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] PV-on-HVM: Only initialize the owner field of struct
device_driver on kernels from 2.6.10 onward. The field was not
available until then.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] Exclude support for /proc/xen/xsd_kva when building a
non-privileged guest.
This is useful for PV-on-HVM because it removes code which would
otherwise require extra code in the compatability shim.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] PV-on-HVM: Remove the attr parameter from device attribute
show methods on kernels prior to 2.6.13. The parameter was not present
before that.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] Move xenbus backend probing into a separate source file and
only build it when CONFIG_XEN_BACKEND is set.
This removes unused code from frontend only configurations and also
makes PV-on-HVM drivers on older kernels simpler by removing code
which would otherwise require extra code in the compatability shim.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
PV-on-HVM: Include a Makefile in each subdirectory to maintain
compatability with kernels from before Kbuild files were introduced.
This follows best practice as described in
Documentation/kbuild/modules.txt
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Ian Campbell [Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)]
[LINUX] PV-on-HVM: Directly include headers which are used in various
files rather than relying on them being included indirectly.
This is required because these headers are not pulled in indirectly on
older kernels.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 11:30:08 +0000 (12:30 +0100)]
[XEN] Make memory hypercalls NUMA-aware.
This patch modifies memory ops to use the NUMA-aware page allocator
functions. We use the target domain's VCPU0 placement to determine
which node's memory to use. We expect the system administrator to
utilize the exposed NUMA topology information to help craft guest
config files that are NUMA-friendly (use only processors and memory values
that will fit within a given node).
Signed-off-by: Ryan Harper <ryanh@us.ibm.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 11:28:46 +0000 (12:28 +0100)]
[XEN] NUMA-ify Xen heap and page allocator
This patch adds a per-node bucket to the heap structure in Xen.
During heap initialization the patch determines which bucket to place
the memory. We reserve guard pages between node boundaries in the case
that said boundary isn't already guarded by the MAX_ORDER boundary to
prevent the buddy allocator from merging pages between nodes.
Signed-off-by: Ryan Harper <ryanh@us.ibm.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 11:25:54 +0000 (12:25 +0100)]
[XEN] Add basic NUMA/SRAT support to Xen from Linux 2.6.16.29.
Signed-off-by: Ryan Harper <ryanh@us.ibm.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 10:51:23 +0000 (11:51 +0100)]
merge
kfraser@localhost.localdomain [Wed, 25 Oct 2006 10:50:54 +0000 (11:50 +0100)]
[HVM] Move ACPI timer to HV, which is the last platform timer in Qemu.
We found Vista polls ACPI timer very frequently (about 15 times
averagely) when handling timer (RTC @ 64HZ) interrupt routine. Though
the exact reason is known, it should be related to system time
adjustment. When it's in Qemu, the overhead is big. After moving,
Vista's idle overhead decreases dramatically from ~10% to 0.9%.=20
Another benefit is that Vista can only pass Performance rating with
this patch. The root cause is that ACPI timer in Qemu isn't
synchronous with other platform timer in HV, which results in Vista
complains "can't measure TSC frequency".
This patch changes vpit.h to vpt.h, for it not only has pit structure
in it, but other platform timer's structure. Another change is moving
ACPI timer and related address from acpi.h to ioreq.h, which can be shared
by HV and ACPI firmware.
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
Tim Deegan [Wed, 25 Oct 2006 10:44:58 +0000 (11:44 +0100)]
[XEND] Be more generous with the default shadow allocation.
Allow enough shadow memory to avoid thrashing the shadow pages,
rather than just enough for safety.
Signed-off-by: Tim Deegan <Tim.Deegan@xensource.com>
Tim Deegan [Wed, 25 Oct 2006 10:44:58 +0000 (11:44 +0100)]
[XEND] Be more generous with the default shadow allocation.
Allow enough shadow memory to avoid thrashing the shadow pages,
rather than just enough for safety.
Signed-off-by: Tim Deegan <Tim.Deegan@xensource.com>
Tim Deegan [Wed, 25 Oct 2006 10:39:57 +0000 (11:39 +0100)]
[HVM] Avoid buffer overrun in qemu-dm
The array offset in set_bits_in_row here comes from an otherwise un-checked
VNC client request.
Signed-off-by: Tim Deegan <Tim.Deegan@xensource.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 09:59:00 +0000 (10:59 +0100)]
[BLOCK] blkback: Fix potential grant entry leaks on error
As it stands grant entries for the actual data are mapped in bulk.
If one of the earlier entries fail to be mapped, it can cause all
subsequent entries to be leaked if they were successfully mapped.
This patch changes it so that we will continue to reap grant entries
even when an error is detected.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 09:56:50 +0000 (10:56 +0100)]
[BLKTAP] Simplify linked-list insertion/deletion.
This should also avoid (bogus) compiler warnings, as reported
on IA64.
Signed-off-by: Keir Fraser <keir@xensource.com>
kfraser@localhost.localdomain [Wed, 25 Oct 2006 09:27:03 +0000 (10:27 +0100)]
[XEND] Open xend-debug.log in append mode.
Signed-off-by: John Levon <john.levon@sun.com>